#define _CRT_SECURE_NO_WARNINGS 1


#include <stdio.h>
#include <string.h>

void exchange(char* str)
{
    int left = 0;
    int right = strlen(str) - 1;
    while (left <= right)
    {
        char temp = *(str + left);
        *(str + left) = *(str + right);
        *(str + right) = temp;
        left++;
        right--;
    }
    for (int i = 0; i < strlen(str); i++)
    {
        printf("%c", *(str + i));
    }
}

int main()
{
    char str[10000];
    gets_s(str);
    int n = strlen(str);
    exchange(str);
    return 0;
}